From bde7654db8e9cbc78f6f12f007fdabef10f8c4dc Mon Sep 17 00:00:00 2001 From: Rob Browning Date: Fri, 15 Oct 2010 22:51:45 -0500 Subject: [PATCH] Prevent mail destined for mail-archive-file-name from being lost. --- debian/changelog | 9 +++- ...utput-to-mail-with-live-rmail-buffers.diff | 49 +++++++++++++++++++ debian/patches/series | 1 + 3 files changed, 58 insertions(+), 1 deletion(-) create mode 100644 debian/patches/fix-gnus-output-to-mail-with-live-rmail-buffers.diff diff --git a/debian/changelog b/debian/changelog index c8176fa4d08..377fb3d8b3c 100644 --- a/debian/changelog +++ b/debian/changelog @@ -8,7 +8,14 @@ emacs23 (23.2+1-5) unstable; urgency=low to Carl Worth and Sven Joachim for finding the patches (closes: #586459). - -- Rob Browning Sun, 17 Oct 2010 23:53:54 -0500 + * Apply upstream patch to prevent mail destined for + mail-archive-file-name from being lost + (fix-gnus-output-to-mail-with-live-rmail-buffers.diff). Thanks to + Jeroen Nijhof for the report and Sven + Joachim for tracking down the patch. + (closes: #597255) + + -- Rob Browning Mon, 18 Oct 2010 00:14:01 -0500 emacs23 (23.2+1-4) unstable; urgency=low diff --git a/debian/patches/fix-gnus-output-to-mail-with-live-rmail-buffers.diff b/debian/patches/fix-gnus-output-to-mail-with-live-rmail-buffers.diff new file mode 100644 index 00000000000..bcc07dcc752 --- /dev/null +++ b/debian/patches/fix-gnus-output-to-mail-with-live-rmail-buffers.diff @@ -0,0 +1,49 @@ +* Fcc should work properly even if the buffer is being visited in rmail-mode. + Patch: fix-gnus-output-to-mail-with-live-rmail-buffers.diff + Provided-by: Sven Joachim + Date: Tue, 21 Sep 2010 08:14:57 +0200 + Added-by: Rob Browning + Status: incorporated upstream + + The Debian patch is taken from this upstream commit: + + revno: 100052 + committer: Glenn Morris + branch nick: emacs-23 + timestamp: Mon 2010-09-20 20:11:34 -0700 + message: + Fix message-mode bug with fcc to Rmail buffers. + + * lisp/gnus/message.el (message-output): Use gnus-output-to-rmail if a + buffer is visiting the fcc file in rmail-mode. + +--- a/lisp/gnus/ChangeLog ++++ b/lisp/gnus/ChangeLog +@@ -1,3 +1,8 @@ ++2010-09-21 Glenn Morris ++ ++ * message.el (message-output): Use gnus-output-to-rmail if a buffer is ++ visiting the fcc file in rmail-mode. ++ + 2010-04-22 Andreas Seltenreich + + * message.el (message-generate-headers): Record insertion of optional +--- a/lisp/gnus/message.el ++++ b/lisp/gnus/message.el +@@ -5322,8 +5322,14 @@ + + (defun message-output (filename) + "Append this article to Unix/babyl mail file FILENAME." +- (if (and (file-readable-p filename) +- (mail-file-babyl-p filename)) ++ (if (or (and (file-readable-p filename) ++ (mail-file-babyl-p filename)) ++ ;; gnus-output-to-mail does the wrong thing with live, mbox ++ ;; Rmail buffers in Emacs 23. ++ ;; http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=597255 ++ (let ((buff (find-buffer-visiting filename))) ++ (and buff (with-current-buffer buff ++ (eq major-mode 'rmail-mode))))) + (gnus-output-to-rmail filename t) + (gnus-output-to-mail filename t))) + diff --git a/debian/patches/series b/debian/patches/series index 13bb896f75e..a168d60aa17 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -13,3 +13,4 @@ fix-gnu-kfreebsd-startup.diff prevent-string-stack-overflow.diff prevent-let-eval-apply-stack-overflow.diff use-safe-alloca-lisp-in-let-eval-apply-apply_lambda.diff +fix-gnus-output-to-mail-with-live-rmail-buffers.diff -- 2.30.2